const path = require('path')
const webpack = require('./node_modules/@types/webpack')
const htmlwebpackplugin = require('./node_modules/html-webpack-plugin')
const { CleanWebpackPlugin } = require('./node_modules/clean-webpack-plugin/dist/clean-webpack-plugin');

module.exports = {
  entry: path.join(__dirname, 'index.js'),
  output: {
    path: path.join(__dirname, 'dist'),
    filename: '[name]-[hash].js' // hash
  },
  mode: 'production',
  plugins: [
    new htmlwebpackplugin(),
    new CleanWebpackPlugin()
  ]
}